<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
    <th:block th:include="include :: header('修改库存表')" />
</head>
<body class="white-bg">
    <div class="wrapper wrapper-content animated fadeInRight ibox-content">
        <form class="form-horizontal m" id="form-stock-edit" th:object="${basStock}">
            <input name="stockId" th:field="*{stockId}" type="hidden">

            <div class="form-group">    
                <label class="col-sm-3 control-label">货位编码：</label>
                <div class="col-sm-8">
                    <input name="cargoSpaceId" th:field="*{cargoSpaceId}" class="form-control" type="text" readonly>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">托盘条码：</label>
                <div class="col-sm-8">
                    <input name="trayCode" th:field="*{trayCode}" class="form-control" type="text" readonly>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">物品编码：</label>
                <div class="col-sm-8">
                    <input name="productId" th:field="*{productId}" class="form-control" type="text" readonly>

                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">物品名称：</label>
                <div class="col-sm-8">
                    <input name="productId" th:field="*{lineId}" class="form-control" type="text" readonly>

                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">物品状态：</label>
                <div class="col-sm-8">
                    <select name="productStatus" class="form-control" th:with="type=${@dict.getType('product_status')}">
                        <option th:each="dict : ${type}" th:text="${dict.dictLabel}"
                                th:value="${dict.dictValue}"th:field="*{productStatus}"></option>
                    </select>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">批号：</label>
                <div class="col-sm-8">
                    <input name="lotNo" th:field="*{lotNo}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">库存数量：</label>
                <div class="col-sm-8">
                    <input name="quantity" th:field="*{quantity}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">供应商：</label>
                <div class="col-sm-8">
                    <input name="inDate" th:field="*{inClassName}" class="form-control" type="text" readonly>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">入库日期：</label>
                <div class="col-sm-8">
                    <input name="inDate" th:field="*{inDate}" class="form-control" type="text" readonly>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">回流日期：</label>
                <div class="col-sm-8">
                    <input name="inDate" th:field="*{backDate}" class="form-control" type="text" readonly>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">生产时间：</label>
                <div class="col-sm-8">
                    <input name="classId" th:field="*{classId}" class="form-control" type="text" >
                </div>
            </div>

        </form>
    </div>
    <th:block th:include="include :: footer" />
    <script th:inline="javascript">
        var prefix = ctx + "stock/stock";
        $("#form-stock-edit").validate({
            focusCleanup: true
        });

        function submitHandler() {
            if ($.validate.form()) {
                $.operate.save(prefix + "/edit", $('#form-stock-edit').serialize());
            }
        }
    </script>
</body>
</html>